﻿
using System;

using GECS.Core;
using GECS.Object;

namespace GECS.Test {

	public class Object1 : GObject {

		public Object1(float x, float y) : base(GameTest.RIGHT, x, y) {
			VelocityX = 4;
			VelocityY = 4;
		}
		
		public override void Update(long elapsedTime){
			if (X+Width > Global.WIDTH || X < 0){
				VelocityX = -VelocityX;
			}
			if (Y+Height > Global.HEIGHT || Y < 0){
				VelocityY = -VelocityY;
			}
		}

    }
	
}
